import request from '@/utils/request'

/**
 * 获取组织架构
 * **/
export const getPermissionListAPI = () => request.get('/sys/permission')

/**
 * 新增组织架构
 * **/
export const addPermissionAPI = (data) => request.post('/sys/permission', data)

/** **
 * 删除组织架构
 * **/
export const delPermissionAPI = id => request.delete(`/sys/permission/${id}`)

/** **
 * 获取组织架构详情
 * **/
export const getPermissionDetailAPI = id => request.get(`/sys/permission/${id}`)

/** *
 * 更新组织架构
 * ***/
export const updatePermissionAPI = data => request.put(`/sys/permission/${data.id}`, data)
